#!/bin/sh
#安装前执行脚本
echo "killall CloudMonitoring"
killall -9 CloudMonitoring
killall -9 CloudMonitoring_

myFile="/Library/LaunchDaemons/com.Y3.WeChatTool.plist"

echo "pre exist plist?"
if [ -f "$myFile" ];
then
#暂停进程
echo "run stop"
launchctl stop com.Y3.WeChatTool

echo "run unload"
launchctl unload -w "$myFile"
else
echo "not exist"
fi
